﻿<%@ Page Title="" Language="C#" MasterPageFile="../main.master" Trace="false" %>
<%@ Import Namespace="System.Reflection" %>

<script runat="server">
	protected void Page_Load(object sender, EventArgs e)
	{
		//현재 어셈블리 버전
		WebCurrentVersionLiteral.Text = GetVersion(Assembly.GetAssembly(typeof(VioletDevelopmentLaboratory.Net.Web.VUtility)));

		//최신 어셈블리 버전
		VBoardVersionCheckService.VBoardVersionCheck lastVersion = new VBoardVersionCheckService.VBoardVersionCheck();
		WebLastVersionLiteral.Text = lastVersion.GetAssemblyLastVersion();
	}

	private string GetVersion(Assembly assembly)
	{
		foreach (string info in assembly.FullName.Split(new char[] { ',' }))
		{
			if (info.Trim().ToLower().IndexOf("version") > -1)
			{
				return info.Substring(9);
			}
		}

		return "0.0.0.0";
	}
</script>

<asp:Content ID="Content1" ContentPlaceHolderID="BodyContentPlaceHolder" Runat="Server">
	<dl>
		<dt>VioletDevelopmentLaboratory.Net.Web.dll</dt>
		<dd>현재버전 : <asp:Literal ID="WebCurrentVersionLiteral" runat="server" /></dd>
		<dd>최신버전 : <asp:Literal ID="WebLastVersionLiteral" runat="server" /></dd>
	</dl>
</asp:Content>

